1. /* sfoequal.cpp by K.Tsuru */
  2. // function ID = 7003 DRADIX
  3. /**************************************
  4. SFraction class
  5. It provides the relation operator ==().
  6. **************************************/
  7. #ifndef SN_H
  8. #include "sn.h"
  9. #endif
  10. bool operator==(const SFraction& m, const SFraction& n){
  11. if(m.Sign(7003) != n.Sign(7003)) return 0;
  12. if(m.ReduceDone() && n.ReduceDone()){ //Both are irreducible fractions.
  13. if(LLCompare(m.NumNR(), n.NumNR())) return 0; //different numerator
  14. if(LLCompare(m.DenNR(), n.DenNR())) return 0; //different denominator
  15. return 1;
  16. }
  17. SFraction t;
  18. if( FFCompare(m, n) ) return 0;
  19. return 1;
  20. }

sfoequal.cpp : last modifiled at 2015/07/25 14:11:48(647 bytes)
created at 2015/12/22 16:07:29
The creation time of this html file is 2016/09/13 19:56:38 (Tue Sep 13 19:56:38 2016).